/**
  ******************************************************************************
  * @file    USART_app.h
  * @author  Thongnh
  * @version V1.0
  * @date    18-07-2011
  * @brief   Main process of USART
  ******************************************************************************
  * @attention
  *
  * THE PRESENT FIRMWARE WHICH IS FOR GUIDANCE ONLY AIMS AT PROVIDING CUSTOMERS
  * WITH CODING INFORMATION REGARDING THEIR PRODUCTS IN ORDER FOR THEM TO SAVE
  * TIME. AS A RESULT, XICUTELECTRONICS SHALL NOT BE HELD LIABLE FOR ANY
  * DIRECT, INDIRECT OR CONSEQUENTIAL DAMAGES WITH RESPECT TO ANY CLAIMS ARISING
  * FROM THE CONTENT OF SUCH FIRMWARE AND/OR THE USE MADE BY CUSTOMERS OF THE
  * CODING INFORMATION CONTAINED HEREIN IN CONNECTION WITH THEIR PRODUCTS.
  *
  * <h2><center>&copy; COPYRIGHT 2011 Xicutelectronics</center></h2>
  ******************************************************************************
  */ 

#include "includes.h"

#ifndef __PC_APP_H__
#define __PC_APP_H__

#ifdef USE_PC

typedef enum{
    // PC to board command
    CMD_NULL = 0,
    
    CMD_POLLING,
    CMD_GET_TIME,
    CMD_SET_TIME,
    CMD_GET_RECORD,
    CMD_ERASE_ALL_RECORD,
    
}Command;

typedef enum{
    // define error code 
    NO_ERROR = 0,
    
    COMMAND_NOT_SUPPORT,
    RECORD_INDEX_INCORRECT,
    RECORD_IS_EMPTY,
    
}ErrorCode;

/*
    define lenh cho delphi
    
    CMD_NULL             = 0;
    CMD_POLLING          = 1;
    CMD_GET_TIME         = 2;
    CMD_SET_TIME         = 3;
    CMD_GET_RECORD       = 4;
    CMD_ERASE_ALL_RECORD = 5;
*/

void PC_AppInit(void);
void PC_AppProcess(void);

#endif
#endif
// end of file

